<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=1200, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <button id="btnClick">click</button>
    <script>
        const oButton = document.querySelector('#btnClick')

        oButton.addEventListener('click',(e) =>{
           // window.alert('dadad ');
          // let a = confirm('你是否确定？');
           //alert(a);
        //    let b = prompt('请输入你的姓名','肖继超');
        //    alert(b);
            console.log(navigator.userAgent)
        })
    </script>
</body>
</html>